package cuishifeng.blog.constants;

import cuishifeng.blog.model.BlogTitle;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.function.BiConsumer;


/**
 * @author cuishifeng
 * Created on 2021-02-03
 */
@Getter
@AllArgsConstructor
public enum BlogTitleEnum {

    PREFIX_TITLE("title", BlogTitle::setTitle),
    PREFIX_PUBLISHED("published", BlogTitle::setPublished),
    PREFIX_DESCRIPTION("description", BlogTitle::setDescription),
    PREFIX_TAGS("tags", BlogTitle::setTags),
    PREFIX_COVER_IMAGE("cover_image", BlogTitle::setCover_image),
    PREFIX_CANONICAL_URL("canonical_url", BlogTitle::setCanonical_url),
    ;

    private String name;
    private BiConsumer<BlogTitle, String> consumer;
}
